{template newheader}
<script type="text/javascript" src="{SITE_URL}images/showtalk.js"></script>
<script type="text/javascript">
function talk_del(tid){
	art.dialog.confirm('确定删除吗？', function(){							  
		var url = siteUrl+'index.php?app=talk&ac=do&ts=talk_del';
		$.post(url,{talkid:tid},function(rs){
					if(rs == 0){
						succ('删除成功^_^');
						window.location = siteUrl+'index.php?app=talk';
					}
		})
	});
}

</script>
<div id="wrapper">
<input type="hidden"  id="talkid" value="{$talkid}">
	<div class="main topic">

		<div class="white co5 topic_t">

			<div class="fr to_ava"><a href="{SITE_URL}{tsurl('user','space',array(userid=>$strTopic[user][userid]))}"><img alt="{$strTopic[user][username]}" src="{$strTopic[user][face]}" /></a></div>

			<h1>{$title}</h1>

			<p class="to_data"><a href="{SITE_URL}{tsurl('user','space',array(userid=>$strTopic[user][userid]))}">{$strTopic[user][username]}</a>&nbsp发布于 <span name="formatdate">{php echo date('Y-m-d H:i',$strTopic[addtime])}</span></p>

			<div class="to_detail">

				{$strTopic['content']}

			</div>

			
<!--{if $TS_USER[user][userid] == "1"}-->
<div style="text-align:right;">
<a href="{SITE_URL}index.php?app=talk&ac=talk_edit&talkid={$strTopic[talkid]}">{$TS_HL[app][1066]}{$strShape[shapename]}</a> &gt;&nbsp; <a href="javascript:void(0);" onclick="talk_del('{$strTopic[talkid]}');">{$TS_HL[app][1067]}</a>
</div>
<!--{/if}-->
		</div>

		<ul class="com_list">

							<!--{if is_array($arrTopicComment)}-->
<!--{loop $arrTopicComment $key $item}-->

				<li>

					<div class="com_icon"><a href="{SITE_URL}{tsurl('user','space',array(userid=>$item[user][userid]))}"><img src="{$item[user][face]}" alt="$item[user][username]}"></a></div>

					<div class="com_con">

						<p><span name="formatdate" class="fr date">{php echo date('Y-m-d H:i:s',$item[addtime])}</span><a href="{SITE_URL}{tsurl('user','space',array(userid=>$item[user][userid]))}">{$item[user][username]}</a></p>

						<p class="com_d">{$item[content]}</p>

					</div>

				</li>
				<!--{/loop}-->
<!--{/if}-->

		</ul>

		<h3 class="add_reply">添加回复</h3>

		

			<!--{if intval($TS_USER[user][userid])==0}-->
<div style="border:solid 1px #DDDDDD; text-align:center;padding:20px 0"><a href="{SITE_URL}{tsurl('user','login')}">{$TS_HL[pub][1003]}</a> | <a href="{SITE_URL}{tsurl('user','register')}">{$TS_HL[pub][1004]}</a></div>
<!--{elseif $strTopic[iscomment] == 1 && $strTopic[userid] != $TS_USER[user][userid]}-->
{$TS_HL[app][1075]}
<!--{else}-->
			<div class="post_commet">
			<a id="comments" name="comments"></a>
			<div class="com_icon"><img class="ava" src="{$dangqianuser[user][face]}" alt="{$dangqianuser[user][username]}"></div>
			<div class="com_text">
				<textarea id="comment" placeholder="添加你的评论"></textarea>
				<p class="com_btn"><input class="btn" type="button" value="发表" name="Submit" id="submit" style="display: inline-block; "></p>
			</div>
		</div>
		<!--{/if}-->

		

		

	</div>

	<div class="sidebar">

		<p class="back_to"><a href="{SITE_URL}{tsurl('talk')}">返回话题首页</a></p>

		<div class="white">

			<h2>最新话题</h2>

			<ul class="new_t">

				<!--{loop $newTopic $key $item}-->

				<li><span name="formatdate">>>  </span><a title="{$item[title]}" href="{SITE_URL}{tsurl('talk','talk',array(talkid=>$item[talkid]))}">{$item[title]}</a></li>

				<!--{/loop}-->
				
			</ul>

		</div>

		<p><a href="{SITE_URL}{tsurl('talk','new_talk')}" class="btn">发起新话题</a></p>

	</div>

	<div class="clear"></div>

</div>
{template footer}